<?php
/**
 * Created by b17
 * 3/5/12 8:34 PM
 */

namespace Managers\Widget;

class WeatherWidget extends AbstractWidget
{
    private $_city = 'Toronto';

    public function init()
    {
        parent::init();
        $googleWeather = new \G4T\Api\Weather\Google($this->_city);
        $forecast = $googleWeather->getForecast();
        $this->view->forecast = $forecast;
    }

    /**
     * Название файла для вывода.
     *
     */
    public function getScriptName()
    {
        return "/widget/weather.phtml";
    }
}
